Memory devices using semiconductor elements are roughly classified into a volatile memory device that loses its stored data when power supply is stopped and a nonvolatile memory device that can hold its stored data even when power supply is stopped.
As a typical example of a volatile memory device, a dynamic random access memory (a DRAM) is given. In a DRAM, a transistor included in a memory element is selected and an electric charge is accumulated in a capacitor, so that data is stored.
Owing to the above-described principle, an electric charge in a capacitor is lost when data in a DRAM is read out; thus, it is necessary to perform writing operation whenever data is read. In addition, there is leakage current in a transistor included in a memory element and an electric charge flows into or out of the capacitor even when the transistor is not selected, whereby data holding period is short. Therefore, it is necessary to perform writing operation (refreshing operation) again in a predetermined cycle and it is difficult to reduce power consumption sufficiently. Further, since stored data is lost when the power is not supplied, another memory device using a magnetic material or an optical material is needed to hold stored data for a long time.
As another example of a volatile memory device, a static random access memory (an SRAM) is given. In an SRAM, stored data is held using a circuit such as a flip flop, so that refreshing operation is not needed. In view of this point, an SRAM is more advantageous than a DRAM. However, there is a problem in that cost per storage capacity becomes high because a circuit such as a flip flop is used. Further, in view of the point that stored data is lost when the power is stopped, an SRAM is not superior to a DRAM.
As a typical example of a nonvolatile memory device, a flash memory is given. A flash memory includes a floating gate between a gate electrode and a channel formation region in a transistor. A flash memory stores data by holding an electric charge in the floating gate, so that a data holding period is extremely long (semi-permanent), and thus has an advantage that refreshing operation which is necessary in a volatile memory device is not needed (for example, see Patent Document 1).
However, in a flash memory, there is a problem that a memory element does not function after performing writing operation a numerous number of times because a gate insulating layer included in the memory element is deteriorated due to tunnel current which occurs when writing operation is performed. In order to avoid an adverse effect of this problem, for example, a method of equalizing the number of writing operation for memory elements is employed, for example. However, a complicated peripheral circuit is needed to realize the method. Even when such a method is employed, the basic problem of lifetime is not resolved. That is, a flash memory is unsuitable for application in which data is rewritten with high frequency.
Further, high voltage is required to inject an electric charge to the floating gate or to remove the electric charge in the floating gate. Furthermore, a relatively long time is required for injecting or removing an electric charge and the speed of writing and erasing cannot be easily increased.